package cn.aj.basic.query;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class BaseQuery {
    // 高级查询封装的字段
    private String keyword;

    // 当前页码
    private Integer currentPage;

    // 每页展示的条数
    private Integer pageSize;

    /**
     * @Description: TODO
     * @Author: aj
     * @Version: 1.0
     * @Date:  2022/11/10 0010 11:55
     * 起始页
     */
    public Integer getStart() {
        return (this.currentPage - 1) * this.pageSize;
    }
}
